# 创建群聊
import DID_interface

# groupID="b56e6fc4-43df-4055-b05b-1086b12ae9b5"
# did=["did:p2p_did_chat:Yk6hiAdlTA","did:p2p_did_chat:vpMAvH0TIx"]
# DID_interface.create_and_share_groupkey(groupID,did)




# 群消息加解密
data=[ { "type": "text",
           "content": "你好，Bob！" ,
           "timestamp": "2025-07-10T10:30:00"}]
meg="hello"
groupID="b56e6fc4-43df-4055-b05b-1086b12ae9b5"
did="did:p2p_did_chat:Yk6hiAdlTA"
print(data)
encryptdata=DID_interface.group_meg_encrypt(groupID,did,data)
print(encryptdata)
decryptdata=DID_interface.group_meg_decrypt(groupID,did,encryptdata)
print(decryptdata)
